package org.jeecg.modules.demo.com.kunpeng.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.jeecg.modules.demo.com.kunpeng.entity.CustomerInformation;
import org.jeecg.modules.demo.com.kunpeng.entity.OtherContractDetail;
import org.jeecg.modules.demo.com.kunpeng.entity.OtherContractCollectionPlan;
import org.jeecg.modules.demo.com.kunpeng.entity.OtherContract;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.demo.com.kunpeng.entity.dto.OtherContractKeyWordsQueryDTO;
import org.jeecg.modules.demo.com.kunpeng.vo.OtherContractVO;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

/**
 * @Description: 其他合同表
 * @Author: jeecg-boot
 * @Date:   2022-12-23
 * @Version: V1.0
 */
public interface IOtherContractService extends IService<OtherContract> {

	/**
	 * 添加一对多
	 *
	 * @param otherContract
	 * @param otherContractDetailList
	 * @param otherContractCollectionPlanList
	 */
	public void saveMain(OtherContract otherContract, List<OtherContractDetail> otherContractDetailList, List<OtherContractCollectionPlan> otherContractCollectionPlanList, CustomerInformation customerInformation) ;
	
	/**
	 * 修改一对多
	 *
   * @param otherContract
   * @param otherContractDetailList
   * @param otherContractCollectionPlanList
	 */
	public void updateMain(OtherContract otherContract,List<OtherContractDetail> otherContractDetailList,List<OtherContractCollectionPlan> otherContractCollectionPlanList);
	
	/**
	 * 删除一对多
	 *
	 * @param id
	 */
	public void delMain (String id);
	
	/**
	 * 批量删除一对多
	 *
	 * @param idList
	 */
	public void delBatchMain (Collection<? extends Serializable> idList);


	/**
	 * 根据合同属性或者合同状态或者关键字查询其他合同数据
	 * @return
	 */
	Page<OtherContractVO> listByKeyWords(Page<OtherContractVO> page, OtherContractKeyWordsQueryDTO otherContractKeyWordsQueryDTO);

	/**
	 * 根据id修改状态
	 * @param id
	 * @param status
	 */
	void updateStateById(String id,String status);
	
}
